Skip to content

Add client-side encrypted bucket transfers and pre-transmit profiling - #61

Closed
kaashmonee wants to merge 2 commits into
rgcsekaraa:mainfrom
candacelabs:feat/encrypted-file-transfers
Closed

kaashmonee wants to merge 2 commits into
rgcsekaraa:mainfrom
candacelabs:feat/encrypted-file-transfers

Conversation

@kaashmonee

@kaashmonee kaashmonee commented Nov 25, 2026 •

Copy link
Copy Markdown

Draft: the current implementation does not meet the required metadata privacy. Names and plaintext lengths must be protected before any provider request. The current commit still exposes the original object key and leaks size. A revised format, tests and fresh measurements are pending.

Summary

Adds opt-in client-side encryption during bucket creation, passphrase unlock, paginated protected listings, and authenticated single-file uploads and downloads. Includes a pinned x86-64 Linux Nix environment and a notebook for profiling the production transfer path. Addresses #60.

Why

A user can keep file contents private from the storage provider while navigating logical filenames in the client. The notebook shows how much CPU and elapsed time the client spends preparing a signed PUT for plain and encrypted files of the same size.

Scope

  • Frontend
  • Rust backend
  • CI/CD
  • Docs

Each protected bucket gets a random key. Its passphrase protects that key and the private display name in a descriptor stored with the bucket. Authenticated encryption binds file contents to the bucket and object key. Object names and sizes remain visible. The initial UI supports single-file transfers up to 1 GiB. It requires a fresh download destination and offers folder navigation and protected download actions in large virtualized lists.

Verification

  • Tested locally. Linux formatting, all-target/all-features Clippy, and the all-features Rust suite passed (160 tests, 13 ignored). Frontend unit/component tests (131), release-script tests (23), TypeScript, ESLint, and the production build passed.
  • Added setup and usage documentation, a notebook with recorded profiles, and the raw-capture command.
  • Added regression coverage. Both Chromium and WebKit exercised pagination from a small protected listing to 121 files, scrolling and downloading the last file. A native test exercises a concurrent session replacement during both successful and failed descriptor reads.

Notes

The sampled profile opens immediately before file encryption and closes in the AWS SDK pre-transmit hook. The request is signed and cancelled before network dispatch. The notebook includes CPU call stacks, paired latency observations, and a switch for taking new captures. The 4 KiB and 8 MiB workloads cover single PUTs.

The feature is already prototyped in a fork. Feedback on the format, integration boundaries and review scope is welcome. Executed notebook and raw profiles

@kaashmonee
kaashmonee marked this pull request as draft November 25, 2026 02:53
@kaashmonee kaashmonee closed this Nov 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant